﻿using System;
using System.Collections.Generic;
using System.Text;
using Pixysoft.Framework.Reflection;
using Pixysoft.Weblications.Sango.Dao;
using Pixysoft.Weblications.Sango.Constant;
using Pixysoft.Weblications.Sango.Formular;

namespace Pixysoft.Weblications.Sango.Command.officer
{
    partial class SangoOfficerHandler
    {
        public officer_upgradeextrainfo officer_upgradeextrainfo()
        {
            string userCode = SangoManager.Authentication();

            officer_upgradeextrainfo response = ReflectionManager.CreatePojo<officer_upgradeextrainfo>();
            response.Succeed = false;

            Entities.Usr_Building officerBuilding = UsrBuildingDao.getUserBuilding(userCode, CtiBuildingTypecodeCollection.TRAIN);

            response.upgradeextrasoulvalue = OfficerFormular.getUpgradeExtraCostSoulValue(officerBuilding.Buildinglevel);
            response.upgradeextravalue = OfficerFormular.getUpgradeExtraExperienceValue(officerBuilding.Buildinglevel);

            response.Succeed = true;
            return response;
        }
    }

    public interface officer_upgradeextrainfo : ISangoResponse
    {
        long upgradeextrasoulvalue { get;set;}
        long upgradeextravalue { get;set;}
    }
}
